<div class="navbar navbar-default navbar-static-top" role="navigation">
  <div class="container">
    <div class="navbar-header">         
      <a class="navbar-brand" href="/">初心在线小说网站</a>
    </div>
    <div class="navbar-collapse collapse">
      <ul class="nav navbar-nav navbar-right">

        <% if (locals.username) { %> 
          <li><a href="#">        
                <%= username %>          
          </a></li>
          <li><a href="/test">        
                test        
          </a></li>
          <li><a href="/logout">安全退出</a></li> 
        <% } %>           
      </ul>
    </div>              
  </div>
</div>